1. Field of the Invention
The present invention relates to a numerical controller, and especially relates to a numerical controller which learns a tool state causing machining defects.
2. Description of the Related Art
As for a general tool used in machining, a cutting edge is abraded away and cutting resistance is increased with the elapse of machining time, and eventually the tool is broken. Further, machining accuracy is degraded along with progress of abrasion and accordingly, it becomes impossible to maintain predetermined machining accuracy required for a workpiece. In order to avoid such matter of tools, whether or not a tool has reached the end of life is determined mainly at the following timing, and tool exchange is performed when it is determined that the tool has reached the end of life.                At a time at which the number of times or time in which the tool is used exceeds a certain number (life value)        At a time at which it is found that an abrasion amount exceeds a certain number by measuring the tool length        At a time at which an operator determines that the tool has reached the lifetime limit by visually checking the tool or a machined workpiece        At a time at which breakage or chipping is recognized by checking a load of a spindle        
As the prior art technique for determining whether or not a tool has reached the end of life, Japanese Patent Application Laid-Open No. 2000-198047, for example, discloses a technique in which the abrasion amount after machining is calculated based on a tool shape, a cutting condition, and an uncut amount of a workpiece so as to determine a reach to an end of a tool life before machining.
However, the above-mentioned method for determining a tool life has various problems. In the method for determining a tool life based on the number of times or time in which the tool is used, a lifetime value is commonly set by more than enough number of times of use or use time so as to avoid machining defects or breakage, so that the tool is often still usable and thus the cost is wasted. The method for determining a tool life based on the tool length of a tool has such a problem that it is impossible to detect cracks of a chip in the case where there are a plurality of blades or where a blade is positioned at the end. Further, in the case of a tool whose life is determined based on abrasion on a portion other than the end portion, such as a tapping tool, it is impossible to determine a tool life by measurement of the end portion. In the method for determining a tool life based on operator's visual check of a machined workpiece, an operator having technical knowledge needs to perform the operation and thus, this method is not suitable for an unattended operation. In the method for determining a tool life by checking a spindle load, slight chipping hardly causes change of the spindle load, causing difficulty in accurate detection.
Further, in the above-mentioned method for determining a tool life described in Japanese Patent Application Laid-Open No. 2000-198047, accuracy in determination of a tool life is enhanced by considering a tool shape, a cutting condition, and an uncut amount of a workpiece. However, the tool life cannot be determined merely based on the abrasion amount of a tool. The tool life is affected also by a material of the tool, a position of abrasion, an abrasion state (chipping, for example), and the like. Thus, the technique of Japanese Patent Application Laid-Open No. 2000-198047 still has a problem that the technique cannot cope with various situations.